package com.bbjob.controller.client;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

import com.bbjob.dto.Result;
import com.bbjob.model.DeliveryExamineeScores;
import com.bbjob.service.IExamineeScoresService;

@Api(tags = "examieescoresApi", description = "考生成绩管理")
@RestController
@RequestMapping(path = "client/examieescores", produces = "application/json;charset=utf-8")
public class ClientExamineeScoresController {
	
	@Resource
	private IExamineeScoresService scoreService;

	@ApiOperation(value="保存考试成绩", notes="保存考试成绩")
	@RequestMapping(value="save", method=RequestMethod.POST)
	public Result save(HttpServletRequest request,  @RequestParam(value="file", required=false) MultipartFile multipartFile) {
		
		DeliveryExamineeScores ret = scoreService.saveByEntity(request, multipartFile);
		
		return new Result(ret);
	}
}
	